﻿<MSwitch @bind-Value="html" HideDetails="true" Label="html: Enable HTML tags in source"></MSwitch>
<MSwitch @bind-Value="breaks" HideDetails="true" Label="breaks: Convert '\n' in paragraphs into <br>"></MSwitch>
<MSwitch @bind-Value="linkify" HideDetails="true" Label="linkify: Autoconvert URL-like text to links"></MSwitch>
<MSwitch @bind-Value="typographer" HideDetails="true"
         Label="typographer: Enable some language-neutral replacement + quotes beautification"></MSwitch>

<MSheet Outlined>
  <MMarkdownIt Source="@source"
               Html="@html"
               Breaks="breaks"
               Linkify="linkify"
               Typographer="typographer"
               Class="mt-4 pa-1"/>
</MSheet>

@code {

  private string source = @"
- html: 
  <b>Bold</b>
- breaks:
  Convert '\n' in paragraphs into <br>
- linkify:
  https://docs.masastack.com
- typographer:
  ""Smartypants, double quotes"" and 'single quotes'
";

  private bool html;
  private bool breaks;
  private bool linkify;
  private bool typographer;

}
